package com.tancire.member.controller;

import com.tancire.common.core.controller.BaseController;
import com.tancire.common.core.domain.AjaxResult;
import com.tancire.member.domain.MemberTrainChart;
import com.tancire.member.service.IMemberTrainChartService;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

import javax.annotation.Resource;
import java.util.List;

/**
 * 会员排行榜Controller
 *
 * @author tancire
 * @date 2024-10-23
 */
@RestController
@RequestMapping("/open/mobile/memberTrainChart")
public class MemberTrainChartOpenController extends BaseController {

    @Resource
    private IMemberTrainChartService memberTrainChartService;

    /**
     * 查询会员排行榜列表
     */
    @GetMapping("/list")
    public AjaxResult list() {
        List<MemberTrainChart> list = memberTrainChartService.selectMemberTrainChartTop();
        return AjaxResult.success("查询成功", list);
    }

}
